Optimal. Leaf size=73 \[ -\frac{2 i a^7}{d (a-i a \tan (c+d x))^2}+\frac{4 i a^6}{d (a-i a \tan (c+d x))}-\frac{i a^5 \log (\cos (c+d x))}{d}+a^5 x \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0550322, antiderivative size = 73, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 24, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.083, Rules used = {3487, 43} \[ -\frac{2 i a^7}{d (a-i a \tan (c+d x))^2}+\frac{4 i a^6}{d (a-i a \tan (c+d x))}-\frac{i a^5 \log (\cos (c+d x))}{d}+a^5 x \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3487
Rule 43
Rubi steps
\begin{align*} \int \cos ^4(c+d x) (a+i a \tan (c+d x))^5 \, dx &=-\frac{\left (i a^5\right ) \operatorname{Subst}\left (\int \frac{(a+x)^2}{(a-x)^3} \, dx,x,i a \tan (c+d x)\right )}{d}\\ &=-\frac{\left (i a^5\right ) \operatorname{Subst}\left (\int \left (\frac{4 a^2}{(a-x)^3}-\frac{4 a}{(a-x)^2}+\frac{1}{a-x}\right ) \, dx,x,i a \tan (c+d x)\right )}{d}\\ &=a^5 x-\frac{i a^5 \log (\cos (c+d x))}{d}-\frac{2 i a^7}{d (a-i a \tan (c+d x))^2}+\frac{4 i a^6}{d (a-i a \tan (c+d x))}\\ \end{align*}
Mathematica [A] time = 0.625467, size = 110, normalized size = 1.51 \[ \frac{a^5 (\cos (2 c+7 d x)+i \sin (2 c+7 d x)) \left (\cos (2 (c+d x)) \left (-i \log \left (\cos ^2(c+d x)\right )+2 d x-i\right )+\sin (2 (c+d x)) \left (-\log \left (\cos ^2(c+d x)\right )-2 i d x+1\right )+2 i\right )}{2 d (\cos (d x)+i \sin (d x))^5} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.069, size = 146, normalized size = 2. \begin{align*}{\frac{-{\frac{5\,i}{4}}{a}^{5} \left ( \cos \left ( dx+c \right ) \right ) ^{4}}{d}}-{\frac{i{a}^{5}\ln \left ( \cos \left ( dx+c \right ) \right ) }{d}}-{\frac{{\frac{i}{2}}{a}^{5} \left ( \sin \left ( dx+c \right ) \right ) ^{2}}{d}}-{\frac{5\,{a}^{5}\cos \left ( dx+c \right ) \left ( \sin \left ( dx+c \right ) \right ) ^{3}}{4\,d}}-{\frac{11\,{a}^{5}\sin \left ( dx+c \right ) \cos \left ( dx+c \right ) }{4\,d}}+{a}^{5}x+{\frac{{a}^{5}c}{d}}-{\frac{{\frac{11\,i}{4}}{a}^{5} \left ( \sin \left ( dx+c \right ) \right ) ^{4}}{d}}+{\frac{11\,{a}^{5}\sin \left ( dx+c \right ) \left ( \cos \left ( dx+c \right ) \right ) ^{3}}{4\,d}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.80468, size = 119, normalized size = 1.63 \begin{align*} \frac{8 \,{\left (d x + c\right )} a^{5} + 4 i \, a^{5} \log \left (\tan \left (d x + c\right )^{2} + 1\right ) - \frac{32 \, a^{5} \tan \left (d x + c\right )^{3} - 48 i \, a^{5} \tan \left (d x + c\right )^{2} - 16 i \, a^{5}}{\tan \left (d x + c\right )^{4} + 2 \, \tan \left (d x + c\right )^{2} + 1}}{8 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.15905, size = 142, normalized size = 1.95 \begin{align*} \frac{-i \, a^{5} e^{\left (4 i \, d x + 4 i \, c\right )} + 2 i \, a^{5} e^{\left (2 i \, d x + 2 i \, c\right )} - 2 i \, a^{5} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right )}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 0.935863, size = 82, normalized size = 1.12 \begin{align*} - 2 a^{5} \left (\begin{cases} - \frac{i e^{2 i d x}}{2 d} & \text{for}\: d \neq 0 \\x & \text{otherwise} \end{cases}\right ) e^{2 i c} + 2 a^{5} \left (\begin{cases} - \frac{i e^{4 i d x}}{4 d} & \text{for}\: d \neq 0 \\x & \text{otherwise} \end{cases}\right ) e^{4 i c} - \frac{i a^{5} \log{\left (e^{2 i d x} + e^{- 2 i c} \right )}}{d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.55009, size = 608, normalized size = 8.33 \begin{align*} \frac{-384 i \, a^{5} e^{\left (16 i \, d x + 8 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 3072 i \, a^{5} e^{\left (14 i \, d x + 6 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 10752 i \, a^{5} e^{\left (12 i \, d x + 4 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 21504 i \, a^{5} e^{\left (10 i \, d x + 2 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 21504 i \, a^{5} e^{\left (6 i \, d x - 2 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 10752 i \, a^{5} e^{\left (4 i \, d x - 4 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 3072 i \, a^{5} e^{\left (2 i \, d x - 6 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 26880 i \, a^{5} e^{\left (8 i \, d x\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 384 i \, a^{5} e^{\left (-8 i \, c\right )} \log \left (e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right ) - 192 i \, a^{5} e^{\left (20 i \, d x + 12 i \, c\right )} - 1152 i \, a^{5} e^{\left (18 i \, d x + 10 i \, c\right )} - 2304 i \, a^{5} e^{\left (16 i \, d x + 8 i \, c\right )} + 8064 i \, a^{5} e^{\left (12 i \, d x + 4 i \, c\right )} + 16128 i \, a^{5} e^{\left (10 i \, d x + 2 i \, c\right )} + 9216 i \, a^{5} e^{\left (6 i \, d x - 2 i \, c\right )} + 2880 i \, a^{5} e^{\left (4 i \, d x - 4 i \, c\right )} + 384 i \, a^{5} e^{\left (2 i \, d x - 6 i \, c\right )} + 16128 i \, a^{5} e^{\left (8 i \, d x\right )}}{384 \,{\left (d e^{\left (16 i \, d x + 8 i \, c\right )} + 8 \, d e^{\left (14 i \, d x + 6 i \, c\right )} + 28 \, d e^{\left (12 i \, d x + 4 i \, c\right )} + 56 \, d e^{\left (10 i \, d x + 2 i \, c\right )} + 56 \, d e^{\left (6 i \, d x - 2 i \, c\right )} + 28 \, d e^{\left (4 i \, d x - 4 i \, c\right )} + 8 \, d e^{\left (2 i \, d x - 6 i \, c\right )} + 70 \, d e^{\left (8 i \, d x\right )} + d e^{\left (-8 i \, c\right )}\right )}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]